Main
2018-01-03

Vim revelation of the day: wildmode

How often had I been annoyed by Vims command and file autocompletion. I was sure I had looked into this in the past – was that just imagination or was I searching the wrong terms? Now I finally stumbled over the right options:

set wildmenu
set wildmode=longest:full
set wildignore+=*.a,*.o,*.hi
set wildignore+=*.pdf,*.gz,*.aux,*.out,*.nav,*.snm,*.vrb

Wildmenu shows a nice list with the completions available. With wildmode you can configure what it should do if multiple commands match. And most important wildignore can make him ignore files that you won't ever want to open (for example binary files) by file extension.

vim en


Creative Commons License Vim revelation of the day: wildmode by Michael F. Schönitzer is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.